<template>
  <div>
    <h2>我是子组件</h2>
    <button @click="tellFather">xxx</button>
  </div>
</template>

<script>
export default {
  // 6.
  props: {
    num: {
      type: Number
    }
  },
  methods: {
    // 7.
    tellFather () {
      this.$emit('xxx', 124)
    }
  }
}
</script>

<style></style>
